﻿// Author:  Marco van Wieren <mailto:mvwieren@gmail.com>
// Year:    2012
// License: Microsoft Public License (Ms-PL)

using Microsoft.SharePoint;

namespace Mvw.SharePoint.Taxonomy.AutoTagging
{
    /// <summary>
    /// This class should be used a delegate to (temporarily) disable list item events
    /// when manipulating a list.
    /// </summary>
    public class HandleEventsFiringEventReceiver : SPItemEventReceiver
    {
        public void DisableEvents()
        {
            EventFiringEnabled = false;
        }

        public void EnableEvents()
        {
            EventFiringEnabled = true;
        }
    }
}
